---
title: "SQL-VP-008: Retrieve the main policy header record"
summary: Retrieves the core policy header record via the Oracle policy-data package — the library's principal retrieval path.
status: draft
owner: SAIF Claims BOF team
last_reviewed: 2026-08-21
library: SAIF.Business.View.Policy
reference_type: embedded
---

# SQL-VP-008 Retrieve the main policy header record

The primary retrieval statement for `clsPolicyData`, the library's central aggregate policy-view
object. Enforces [BR-VP-001](../business-rules.md#br-vp-001-valid-policy-number-required) after
population.

## Classification

| Field | Value |
| --- | --- |
| **SQL ID** | SQL-VP-008 |
| **Operation type** | Read |
| **Execution method** | Stored procedure |
| **Database** | Oracle |
| **Schema** | `[unqualified]**` |
| **Command type** | StoredProcedure |
| **Business object** | `clsPolicyData` |
| **Criteria property** | `RetrieveSQL` |
| **Lifecycle method** | `BeforeRetrieve` / `AfterRetrieve` (`RequestType.Reader`) |

## Parameters

| Parameter | Direction | Type | Max length | Description |
| --- | --- | --- | --- | --- |
| `apolicynum` | Input | Decimal | N/A | Policy number to retrieve. |
| `recordset` | Output (Cursor) | REF CURSOR | N/A | Result set containing the policy header row. |

## Tables

| Table | Access | Columns used |
| --- | --- | --- |
| *(not directly visible — encapsulated in procedure body)* | SELECT | N/A |

## Sample SQL

```sql
BEGIN
  pk73094_policy_data.getpolicy(
    apolicynum => :apolicynum,
    recordset  => :recordset
  );
END;
```

*Call signature reconstructed from `DataRequest.SQLStatement`/`AddParm`/`AddCursorParm` calls; the
procedure body resides in the Oracle database and was not retrieved this run.*

## Operations and processes
- [Retrieve policy header data](../operations/retrieve-policy-header-data.md)

## Business rules
- [BR-VP-001: Valid policy number required](../business-rules.md#br-vp-001-valid-policy-number-required)

> **Note:** Statements marked with `*` were inferred from code structure, naming
> conventions, or contextual evidence where direct confirmation was not available
> in source artifacts. Statements marked with `**` could not be confirmed; treat
> as unknown until verified.

## Sources
- `SAIF.Business.View.Policy\clsPolicyData.vb`
